import java.io.IOException;
import java.net.*;

public class ServerConnect {

	private int port;
	private ServerSocket serverSocket = null;

	public ServerConnect(int port) {
		this.port = port;
	}

	public void connect() throws IOException {
		serverSocket = new ServerSocket(port);
	}

	public ServerSocket getServerSocket() {
		return serverSocket;
	}

	public void disConnect(Socket s) throws NullPointerException,
			Exception {
		if (s != null ) {
			s.close();
			s = null;
		}

	}

}
